﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Data;

namespace BLL
{
    /// <summary>
    /// 广告信息
    /// </summary>
    public class AdInformation
    {
        public AdInformation()
        { }
        DAL.AdInformation dal = new DAL.AdInformation();
        /// <summary>
        /// 广告信息 添加
        /// </summary>
        /// <param name="model">信息实体</param>
        /// <returns>是否执行成功</returns>
        public bool InformationAdd(MODEL.AdInformation model)
        {
            return dal.InformationAdd(model);
        }
        /// <summary>
        /// 广告信息 删除
        /// </summary>
        /// <param name="adId">广告编号</param>
        /// <returns>是否执行成功</returns>
        public bool InformationDel(string adId)
        {
            return dal.InformationDel(adId);
        }
        /// <summary>
        /// 广告信息 更新
        /// </summary>
        /// <param name="model">信息实体</param>
        /// <returns>是否执行成功</returns>
        public bool InformationUpdate(MODEL.AdInformation model)
        {
            return dal.InformationUpdate(model);
        }
        /// <summary>
        /// 广告信息 修改广告状态
        /// </summary>
        /// <param name="model">信息实体</param>
        /// <returns>是否执行成功</returns>
        public bool InformationUpdateState(MODEL.AdInformation model)
        {
            return dal.InformationUpdateState(model);
        }
        /// <summary>
        /// 广告信息 列表
        /// </summary>
        /// <returns>列表</returns>
        public DataSet GetAdInformationList()
        {
            return dal.GetAdInformationList();
        }
        /// <summary>
        /// 广告信息 实体
        /// </summary>
        /// <param name="adId">广告编号</param>
        /// <returns>实体</returns>
        public MODEL.AdInformation GetAdInformationModel(string adId)
        {
            return dal.GetAdInformationModel(adId);
        }
        /// <summary>
        /// 广告信息 最大编号
        /// </summary>
        /// <returns>最大编号</returns>
        public string GetMaxId()
        {
            return dal.GetMaxID();
        }
        /// <summary>
        /// 广告信息 可用广告位
        /// </summary>
        /// <returns>可用广告位</returns>
        public DataSet GetAdpositionList()
        {
            return dal.GetAdpositionList();
        }
    }
    /// <summary>
    /// 广告位信息
    /// </summary>
    public class AdPosition
    {
        public AdPosition()
        { }
        DAL.AdPosition dal = new DAL.AdPosition();
        /// <summary>
        /// 广告位 添加
        /// </summary>
        /// <param name="model">信息实体</param>
        /// <returns>是否执行成功</returns>
        public bool PositionAdd(MODEL.AdPosition model)
        {
            return dal.PositionAdd(model);
        }
        /// <summary>
        /// 广告位 删除
        /// </summary>
        /// <param name="positionId">广告位编号</param>
        /// <returns>是否执行成功</returns>
        public bool PositionDel(string positionId)
        {
            return dal.PositionDel(positionId);
        }
        /// <summary>
        /// 广告位 更新
        /// </summary>
        /// <param name="model">信息实体</param>
        /// <returns>是否执行成功</returns>
        public bool PositionUpdate(MODEL.AdPosition model)
        {
            return dal.PositionUpdate(model);
        }
        /// <summary>
        /// 广告位 可用状态更新
        /// </summary>
        /// <param name="model">信息实体</param>
        /// <returns>是否执行成功</returns>
        public bool PositionUpdateState(MODEL.AdPosition model)
        {
            return dal.PositionUpdateState(model);
        }
        /// <summary>
        /// 广告位 列表
        /// </summary>
        /// <returns>列表</returns>
        public DataSet GetAdPositionList()
        {
            return dal.GetAdPositionList();
        }
        /// <summary>
        /// 广告位 列表
        /// </summary>
        /// <param name="adPage">所在页面</param>
        /// <returns>列表</returns>
        public DataSet GetAdPositionList(string adPage)
        {
            return dal.GetAdPositionList(adPage);
        }
        /// <summary>
        /// 广告位 实体
        /// </summary>
        /// <param name="adId">编号</param>
        /// <returns>实体</returns>
        public MODEL.AdPosition GetAdPositionModel(string positionId)
        {
            return dal.GetAdPositionModel(positionId);
        }
        /// <summary>
        /// 广告位 最大编号
        /// </summary>
        /// <returns>最大编号</returns>
        public string GetMaxId()
        {
            return dal.GetMaxID();
        }

    }
}
